Tables [dbo].[InventoryTransactionLogMain]
Properties
PropertyValue
Created10:31:25 AM Tuesday, March 02, 2010
Last Modified3:54:36 PM Wednesday, March 07, 2012
Columns
NameData TypeMax Length (Bytes)Allow Nulls
Cluster Primary Key PK_InventoryTransactionLogMain: InventoryTransactionLogKeyInventoryTransactionLogKeyuniqueidentifier16
No
TransactionDatedatetime8
No
Indexes IX_InventoryTransactionLogMain_OrderKey: OrderKeyOrderKeyuniqueidentifier16
Yes
Indexes IX_InventoryTransactionLogMain_OrderNumber: OrderNumberOrderNumbernvarchar(50)100
Yes
Vendornvarchar(50)100
Yes
Indexes IX_InventoryTransactionLogMain_ReceiptNumber: ReceiptNumberReceiptNumbernvarchar(50)100
Yes
ReturnAuthorizationnvarchar(50)100
Yes
Notesnvarchar(200)400
Yes
Foreign Keys FK_InventoryTransactionLogMain_UserMain_CreatedBy: [dbo].[UserMain].CreatedByUserKeyCreatedByUserKeyuniqueidentifier16
No
CreatedOndatetime8
No
Foreign Keys FK_InventoryTransactionLogMain_UserMain_UpdatedBy: [dbo].[UserMain].UpdatedByUserKeyUpdatedByUserKeyuniqueidentifier16
No
UpdatedOndatetime8
No
Foreign Keys FK_InventoryTransactionLogMain_SystemEntity: [dbo].[SystemEntity].SystemEntityKeySystemEntityKeyuniqueidentifier16
No
Foreign Keys FK_InventoryTransactionLogMain_GroupMain_Owner: [dbo].[GroupMain].OwnerGroupKeyOwnerGroupKeyuniqueidentifier16
Yes
MarkedForDeleteOndatetime8
Yes
FinalBatchKeyuniqueidentifier16
Yes
OriginatingBatchKeyuniqueidentifier16
Yes
BatchLineStatusCodeint4
Yes
BatchStatusMessagenvarchar(200)400
Yes
Indexes Indexes
NameColumnsUnique
Cluster Primary Key PK_InventoryTransactionLogMain: InventoryTransactionLogKeyPK_InventoryTransactionLogMainInventoryTransactionLogKey
Yes
IX_InventoryTransactionLogMain_OrderKeyOrderKey
IX_InventoryTransactionLogMain_OrderNumberOrderNumber
IX_InventoryTransactionLogMain_ReceiptNumberReceiptNumber
Foreign Keys Foreign Keys
NameColumns
FK_InventoryTransactionLogMain_GroupMain_OwnerOwnerGroupKey->[dbo].[GroupMain].[GroupKey]
FK_InventoryTransactionLogMain_SystemEntitySystemEntityKey->[dbo].[SystemEntity].[SystemEntityKey]
FK_InventoryTransactionLogMain_UserMain_CreatedByCreatedByUserKey->[dbo].[UserMain].[UserKey]
FK_InventoryTransactionLogMain_UserMain_UpdatedByUpdatedByUserKey->[dbo].[UserMain].[UserKey]
SQL Script
CREATE TABLE [dbo].[InventoryTransactionLogMain]
(
[InventoryTransactionLogKey] [uniqueidentifier] NOT NULL,
[TransactionDate] [datetime] NOT NULL,
[OrderKey] [uniqueidentifier] NULL,
[OrderNumber] [nvarchar] (50) COLLATE SQL_Latin1_General_CP1_CI_AS NULL,
[Vendor] [nvarchar] (50) COLLATE SQL_Latin1_General_CP1_CI_AS NULL,
[ReceiptNumber] [nvarchar] (50) COLLATE SQL_Latin1_General_CP1_CI_AS NULL,
[ReturnAuthorization] [nvarchar] (50) COLLATE SQL_Latin1_General_CP1_CI_AS NULL,
[Notes] [nvarchar] (200) COLLATE SQL_Latin1_General_CP1_CI_AS NULL,
[CreatedByUserKey] [uniqueidentifier] NOT NULL,
[CreatedOn] [datetime] NOT NULL,
[UpdatedByUserKey] [uniqueidentifier] NOT NULL,
[UpdatedOn] [datetime] NOT NULL,
[SystemEntityKey] [uniqueidentifier] NOT NULL,
[OwnerGroupKey] [uniqueidentifier] NULL,
[MarkedForDeleteOn] [datetime] NULL,
[FinalBatchKey] [uniqueidentifier] NULL,
[OriginatingBatchKey] [uniqueidentifier] NULL,
[BatchLineStatusCode] [int] NULL,
[BatchStatusMessage] [nvarchar] (200) COLLATE SQL_Latin1_General_CP1_CI_AS NULL
) ON [PRIMARY]

GO
ALTER TABLE [dbo].[InventoryTransactionLogMain] ADD CONSTRAINT [PK_InventoryTransactionLogMain] PRIMARY KEY CLUSTERED ([InventoryTransactionLogKey]) ON [PRIMARY]
GO
CREATE NONCLUSTERED INDEX [IX_InventoryTransactionLogMain_OrderKey] ON [dbo].[InventoryTransactionLogMain] ([OrderKey]) ON [PRIMARY]
GO
CREATE NONCLUSTERED INDEX [IX_InventoryTransactionLogMain_OrderNumber] ON [dbo].[InventoryTransactionLogMain] ([OrderNumber]) ON [PRIMARY]
GO
CREATE NONCLUSTERED INDEX [IX_InventoryTransactionLogMain_ReceiptNumber] ON [dbo].[InventoryTransactionLogMain] ([ReceiptNumber]) ON [PRIMARY]
GO
ALTER TABLE [dbo].[InventoryTransactionLogMain] ADD CONSTRAINT [FK_InventoryTransactionLogMain_GroupMain_Owner] FOREIGN KEY ([OwnerGroupKey]) REFERENCES [dbo].[GroupMain] ([GroupKey])
GO
ALTER TABLE [dbo].[InventoryTransactionLogMain] ADD CONSTRAINT [FK_InventoryTransactionLogMain_SystemEntity] FOREIGN KEY ([SystemEntityKey]) REFERENCES [dbo].[SystemEntity] ([SystemEntityKey])
GO
ALTER TABLE [dbo].[InventoryTransactionLogMain] ADD CONSTRAINT [FK_InventoryTransactionLogMain_UserMain_CreatedBy] FOREIGN KEY ([CreatedByUserKey]) REFERENCES [dbo].[UserMain] ([UserKey])
GO
ALTER TABLE [dbo].[InventoryTransactionLogMain] ADD CONSTRAINT [FK_InventoryTransactionLogMain_UserMain_UpdatedBy] FOREIGN KEY ([UpdatedByUserKey]) REFERENCES [dbo].[UserMain] ([UserKey])
GO
Uses
Used By